/*
 * drv_def.h
 *
 *  Created on: 2016-11-17
 *      Author: m
 */

#ifndef SRC_INCLUDE_DRIVER_DRV_DEF_H_
#define SRC_INCLUDE_DRIVER_DRV_DEF_H_

//major device No
#define MAJ_DEV_NONE            (0)
#define MAJ_DEV_FLOPPY          (1)
#define MAJ_DEV_CDROM           (2)
#define MAJ_DEV_HD              (3)
#define MAJ_DEV_TTY             (4)
#define MAJ_DEV_SCSI_DISK       (5)

#define MAKE_DEV_NO(major, minor) (major << 8 | minor)
#define MAJOR(full_dev_no) (full_dev_no >> 8)
#define MINOR(full_dev_no) (full_dev_no & 0xFF)



#endif /* SRC_INCLUDE_DRIVER_DRV_DEF_H_ */
